﻿//using CommonData.Abs;
//using CommonData.Tools;
//using LibrarySystem.Model;
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;
//using System.Threading.Tasks;
//using System.Windows;
//using System.Windows.Media;

//namespace LibrarySystem.Tools
//{
//    /// <summary>
//    /// 装配主界面树形图对象
//    /// </summary>
//   public  class RigTreeList:RigTreeViewAbsHelper<List<TreeItemModel>>
//    {
//        /// <summary>
//        /// 生成节点间的依赖关系
//        /// </summary>
//        /// <param name="parentId">父节点ID</param>
//        /// <param name="nodes">节点清单</param>
//        /// <returns>返回节点实例对象集合</returns>
//        //public static List<TreeItemModel> GetTree(int parentId,List<TreeItemModel> nodes)
//        //{
//        //    List<TreeItemModel> _mainNodes = nodes.Where( x => x.ParentId == parentId ).ToList<TreeItemModel>();
//        //    List<TreeItemModel> _otherNodes = nodes.Where( x => x.ParentId != parentId ).ToList<TreeItemModel>();
//        //    foreach (TreeItemModel dpt in _mainNodes)
//        //    {
//        //        dpt.Nodes = GetTree( dpt.Id, _otherNodes );
//        //    }
//        //    return _mainNodes;
//        //}
    

//        /// <summary>
//        /// 建立节点对象，可以在此函数内定义节点对象的树形
//        /// </summary>
//        /// <returns>返回定义后的节点对象集合实例</returns>
//        public static List<TreeItemModel> GetDepts()
//        {
//            List<TreeItemModel> _list = new List<TreeItemModel>();
//            //读者管理

//            if (GlobalTracker.User_AuthoritySetting.Au_RederDepartment==1|| GlobalTracker.User_AuthoritySetting.Au_AllReader == 1||GlobalTracker.User_AuthoritySetting.Au_ReaderAdjustment==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 39, ItemContent = "读者管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left12.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_RederDepartment == 1)
//            {
//                //_list.Add( _list.Add( new TreeItemModel(){ Level=2, Id=40,ItemContent=" 读者权限",ParentId=39,IconPath=GlobalPath.Imgs_Path + "读者权限.png"});
//                _list.Add(new TreeItemModel() { Level = 2, Id = 41, ItemContent = " 读者部门", ParentId = 39, IconPath = GlobalPath.Imgs_Path + "读者部门.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_AllReader == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 45, ItemContent = " 所有读者", ParentId = 39, IconPath = GlobalPath.Imgs_Path + "读者权限.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ReaderAdjustment == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 42, ItemContent = " 读者调整", ParentId = 39, IconPath = GlobalPath.Imgs_Path + "读者登记.png" });
//            }
//            //_list.Add( new TreeItemModel(){ Level=2, Id=43,ItemContent=" 图片采集",ParentId=39,IconPath=GlobalPath.Imgs_Path + "导入读者.png"});

//            _list.Add(new TreeItemModel() { Level = 2, Id = 44, ItemContent = " 打印借书证", ParentId = 39, IconPath = GlobalPath.Imgs_Path + "读者罚款.png" });

//            //_list.Add( new TreeItemModel(){ Level=2, Id=45,ItemContent=" 图书采访",ParentId=39,IconPath=GlobalPath.Imgs_Path + "读者挂失.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=46,ItemContent=" 读者注销",ParentId=39,IconPath=GlobalPath.Imgs_Path + "读者注销.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=47,ItemContent=" 查询已删除读者罚款记录",ParentId=39,IconPath=GlobalPath.Imgs_Path + "导入读者.png"});

//            //图书管理
//            if (GlobalTracker.User_AuthoritySetting.Au_Interview==1|| GlobalTracker.User_AuthoritySetting.Au_PressAndValidate == 1|| GlobalTracker.User_AuthoritySetting.Au_ListLoginManager == 1|| GlobalTracker.User_AuthoritySetting.Au_BookList == 1|| GlobalTracker.User_AuthoritySetting.Au_PrintTab==1|| GlobalTracker.User_AuthoritySetting.Au_MARCManager == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 1, ItemContent = "图书管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left1.png" });
//            }
                
                

//            if (GlobalTracker.User_AuthoritySetting.Au_Interview==1)
//            {
//                _list.Add( new TreeItemModel() { Level = 2, Id = 2, ItemContent = " 图书采访", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_1.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_PressAndValidate==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 3, ItemContent = " 催书与验收", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_2.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ListLoginManager==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 4, ItemContent = " 总括登记管理", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_3.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_BookList==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 5, ItemContent = " 图书编目", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_4.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_PrintTab==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 110, ItemContent = " 打印标签", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_5.png" });
//            }
//            //_list.Add( new TreeItemModel(){ Level=2, Id=109,ItemContent=" 打印标签,条码,刊脊",ParentId=1,IconPath=GlobalPath.Imgs_Path+"TSGL_5.png"});

//            if (GlobalTracker.User_AuthoritySetting.Au_MARCManager==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 111, ItemContent = " MARC管理", ParentId = 1, IconPath = GlobalPath.Imgs_Path + "TSGL_5.png" });
//            }



//            // 期刊管理
//            //_list.Add( new TreeItemModel(){ Level=1, Id=6,ItemContent="期刊管理",ParentId=0,IconPath=GlobalPath.Imgs_Path + "Left2.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=7,ItemContent=" 期刊征订",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_1.png"});
//            // _list.Add( new TreeItemModel(){ Level=2, Id=9,ItemContent=" 新刊登到",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_3.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=8,ItemContent=" 期刊详情",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_2.png"});

//            //_list.Add( new TreeItemModel(){ Level=2, Id=10,ItemContent=" 过刊合订",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_4.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=11,ItemContent=" 打印标签,条码,刊脊",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_5.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=13,ItemContent=" 文献剔旧",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_6.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=14,ItemContent=" 文献注销",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_7.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=15,ItemContent=" 期刊资源库",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_8.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=16,ItemContent=" 自动套录",ParentId=6,IconPath=GlobalPath.Imgs_Path + "QKGL_9.png"});

//            //非印刷资料
//            //_list.Add( new TreeItemModel(){ Level=1, Id=112,ItemContent="非印刷资料管理",ParentId=0,IconPath=GlobalPath.Imgs_Path+"Left8.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=113,ItemContent=" 非印刷资料编目",ParentId=112,IconPath=GlobalPath.Imgs_Path+"QKGL_7.png"});

//            if (GlobalTracker.User_AuthoritySetting.Au_RemoveOld == 1|| GlobalTracker.User_AuthoritySetting.Au_CodeChanged == 1|| GlobalTracker.User_AuthoritySetting.Au_Logout == 1|| GlobalTracker.User_AuthoritySetting.Au_Adjustment == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 86, ItemContent = "典藏管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left10.png" });
//            }
//                 //// 馆藏典藏
                

//            if (GlobalTracker.User_AuthoritySetting.Au_RemoveOld==1)
//            {
//                 _list.Add( new TreeItemModel() { Level = 2, Id = 87, ItemContent = " 剔旧", ParentId = 86, IconPath = GlobalPath.Imgs_Path + "信息管理.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_CodeChanged==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 88, ItemContent = " 条码更换", ParentId = 86, IconPath = GlobalPath.Imgs_Path + "新闻管理.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_Logout==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 89, ItemContent = " 注销", ParentId = 86, IconPath = GlobalPath.Imgs_Path + "链接管理.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_Adjustment==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 90, ItemContent = " 调配", ParentId = 86, IconPath = GlobalPath.Imgs_Path + "预约管理.png" });
//            }

//            //_list.Add( new TreeItemModel(){ Level=2, Id=91,ItemContent=" 读者管理",ParentId=86,IconPath=GlobalPath.Imgs_Path + "读者管理.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=92,ItemContent=" 评论管理",ParentId=86,IconPath=GlobalPath.Imgs_Path + "评论管理.png"});

//            //流通管理
//            if (GlobalTracker.User_AuthoritySetting.Au_BorrowManager == 1|| GlobalTracker.User_AuthoritySetting.Au_ReturnManager == 1|| GlobalTracker.User_AuthoritySetting.Au_ReNewManager == 1|| GlobalTracker.User_AuthoritySetting.Au_IndemnityManager == 1|| GlobalTracker.User_AuthoritySetting.Au_AppointmentManager == 1|| GlobalTracker.User_AuthoritySetting.Au_OutofDateManager == 1|| GlobalTracker.User_AuthoritySetting.Au_CommentManager == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 17, ItemContent = "流通管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left3.png" });
//            }
            
//            if (GlobalTracker.User_AuthoritySetting.Au_BorrowManager==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 18, ItemContent = " 借阅管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "图书流通.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ReturnManager==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 19, ItemContent = " 归还管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "图书催还.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ReNewManager==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 21, ItemContent = " 续借管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "单刊流通.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_IndemnityManager == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 23, ItemContent = " 赔书管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "期刊催还.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_AppointmentManager==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 20, ItemContent = " 预约管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "图书预约.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_OutofDateManager==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 22, ItemContent = " 超期管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "合订刊流通.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_CommentManager == 1)
//            {
//                //_list.Add( new TreeItemModel(){ Level=2, Id=24,ItemContent=" 罚金管理",ParentId=17,IconPath=GlobalPath.Imgs_Path + "图书预约.png"});
//                _list.Add(new TreeItemModel() { Level = 2, Id = 26, ItemContent = " 评论管理", ParentId = 17, IconPath = GlobalPath.Imgs_Path + "采访书目统计.png" });
//            }
//            //_list.Add( new TreeItemModel(){ Level=2, Id=27,ItemContent=" 阅览室流通查询",ParentId=17,IconPath=GlobalPath.Imgs_Path + "阅读室流通查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=28,ItemContent=" 阅览室图书借阅统计",ParentId=17,IconPath=GlobalPath.Imgs_Path + "阅读室图书借阅统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=29,ItemContent=" 阅览室期刊借阅统计",ParentId=17,IconPath=GlobalPath.Imgs_Path + "阅读室图书借阅统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=30,ItemContent=" 图书快速流通",ParentId=17,IconPath=GlobalPath.Imgs_Path + "图书快速流通.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=31,ItemContent=" 电子邮件催还",ParentId=17,IconPath=GlobalPath.Imgs_Path + "电子邮件催还.png"});

//            // 电子资源
//            //_list.Add( new TreeItemModel(){ Level=1, Id=32,ItemContent="电子资源",ParentId=0,IconPath=GlobalPath.Imgs_Path + "Left4.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=33,ItemContent=" 电子资源类别",ParentId=32,IconPath=GlobalPath.Imgs_Path+"电子资源类别.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=34,ItemContent=" 电子资源编目",ParentId=32,IconPath=GlobalPath.Imgs_Path+"电子资源编目.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=35,ItemContent=" 电子资源统计编码",ParentId=32,IconPath=GlobalPath.Imgs_Path + "电子资源编码统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=36,ItemContent=" 电子资源浏览",ParentId=32,IconPath=GlobalPath.Imgs_Path + "电子资源浏览.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=37,ItemContent=" 电子资源审核",ParentId=32,IconPath=GlobalPath.Imgs_Path + "电子资源审核.png"});

//            // 馆藏设置
//            //_list.Add( new TreeItemModel(){ Level=1, Id=38,ItemContent="馆藏设置",ParentId=0});


//            //阅览室管理
//            if (GlobalTracker.User_AuthoritySetting.Au_InRoomStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_ReadingState == 1|| GlobalTracker.User_AuthoritySetting.Au_ReadingLogin == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 48, ItemContent = "阅览室管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left6.png" });
//            }

            

//            if (GlobalTracker.User_AuthoritySetting.Au_InRoomStatistic==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 49, ItemContent = " 到馆统计", ParentId = 48, IconPath = GlobalPath.Imgs_Path + "图书查询.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ReadingState==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 50, ItemContent = " 阅览情况", ParentId = 48, IconPath = GlobalPath.Imgs_Path + "期刊查询.png" });
//            }
//            if (GlobalTracker.User_AuthoritySetting.Au_ReadingLogin==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 51, ItemContent = " 阅览登到", ParentId = 48, IconPath = GlobalPath.Imgs_Path + "联合查询.png" });
//            }

//            //_list.Add( new TreeItemModel(){ Level=2, Id=52,ItemContent=" 读者查询",ParentId=48,IconPath=GlobalPath.Imgs_Path + "读者查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=53,ItemContent=" 外借图书查询",ParentId=48,IconPath=GlobalPath.Imgs_Path + "外借图书查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=54,ItemContent=" 图书流通历史",ParentId=48,IconPath=GlobalPath.Imgs_Path + "图书流通历史.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=55,ItemContent=" 外借期刊查询",ParentId=48,IconPath=GlobalPath.Imgs_Path + "外借期刊查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=56,ItemContent=" 期刊流通历史查询",ParentId=48,IconPath=GlobalPath.Imgs_Path + "期刊流通历史查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=57,ItemContent=" 书刊借阅排行榜",ParentId=48,IconPath=GlobalPath.Imgs_Path + "书刊借阅排行榜.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=58,ItemContent=" 读者借阅排行榜",ParentId=48,IconPath=GlobalPath.Imgs_Path + "读者借阅排行榜.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=59,ItemContent=" 联合查询",ParentId=48,IconPath=GlobalPath.Imgs_Path + "联合查询.png"});

//            //// 馆际互借(待开发)
//            //_list.Add( new TreeItemModel(){ Level=1, Id=81,ItemContent="馆际互借",ParentId=0,IconPath=GlobalPath.Imgs_Path + "Left9.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=82,ItemContent=" 馆际流通参数",ParentId=81,IconPath=GlobalPath.Imgs_Path + "馆际流通参数.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=83,ItemContent=" 馆际图书流通",ParentId=81,IconPath=GlobalPath.Imgs_Path + "馆际图书流通.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=84,ItemContent=" 馆际合订刊流通",ParentId=81,IconPath=GlobalPath.Imgs_Path + "馆际合订刊流通.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=85,ItemContent=" 馆际读者罚款",ParentId=81,IconPath=GlobalPath.Imgs_Path + "馆际读者罚款.png"});



//            // 统计报表
//            if (GlobalTracker.User_AuthoritySetting.Au_CirculBorrowStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_ReaderCirculateStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_BookCirculateState == 1|| GlobalTracker.User_AuthoritySetting.Au_Ranking == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 60, ItemContent = "流通统计", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left7.png" });
//            }
              

//            if (GlobalTracker.User_AuthoritySetting.Au_CirculBorrowStatistic==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 25, ItemContent = " 流通借阅统计", ParentId = 60, IconPath = GlobalPath.Imgs_Path + "阅览室管理.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_ReaderCirculateStatistic==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 61, ItemContent = " 读者借阅统计", ParentId = 60, IconPath = GlobalPath.Imgs_Path + "图书采访统计.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_BookCirculateState==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 62, ItemContent = " 图书流通统计", ParentId = 60, IconPath = GlobalPath.Imgs_Path + "采访书目统计.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_Ranking==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 63, ItemContent = " 排行榜", ParentId = 60, IconPath = GlobalPath.Imgs_Path + "总括登记账.png" });
//            }

//            //_list.Add( new TreeItemModel(){ Level=2, Id=64,ItemContent=" 图书编目统计",ParentId=60,IconPath=GlobalPath.Imgs_Path + "图书编目统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=65,ItemContent=" 馆藏图书分类统计",ParentId=60,IconPath=GlobalPath.Imgs_Path + "馆藏图书分类统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=66,ItemContent=" 馆藏期刊分类统计",ParentId=60,IconPath=GlobalPath.Imgs_Path + "馆藏期刊分类统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=67,ItemContent=" 期刊征订统计",ParentId=60,IconPath=GlobalPath.Imgs_Path + "期刊征订统计.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=68,ItemContent=" 书刊流通统计",ParentId=60,IconPath=GlobalPath.Imgs_Path + "书刊流通统计.png"});

//            //// 图书采访
//            //_list.Add( new TreeItemModel(){ Level=1, Id=69,ItemContent="图书采访",ParentId=0,IconPath=GlobalPath.Imgs_Path + "Left8.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=70,ItemContent=" 图书征订",ParentId=69,IconPath=GlobalPath.Imgs_Path + "图书征订.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=71,ItemContent=" 未到催书",ParentId=69,IconPath=GlobalPath.Imgs_Path + "未到催书.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=72,ItemContent=" 书目导入",ParentId=69,IconPath=GlobalPath.Imgs_Path + "书目导入.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=73,ItemContent=" 读者推荐",ParentId=69,IconPath=GlobalPath.Imgs_Path + "读者推荐.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=74,ItemContent=" 批次查重",ParentId=69,IconPath=GlobalPath.Imgs_Path + "批次查重.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=75,ItemContent=" 批量验收",ParentId=69,IconPath=GlobalPath.Imgs_Path + "批次验收.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=76,ItemContent=" 自动查重",ParentId=69,IconPath=GlobalPath.Imgs_Path + "自动查看.png"});

//            // 馆藏统计
//            if (GlobalTracker.User_AuthoritySetting.Au_RoomStruct == 1|| GlobalTracker.User_AuthoritySetting.Au_RoomYearStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_RoomStandardStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_BookInDetails == 1|| GlobalTracker.User_AuthoritySetting.Au_RooListLogin == 1
//                || GlobalTracker.User_AuthoritySetting.Au_PersonalStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_PersonalStatistic == 1|| GlobalTracker.User_AuthoritySetting.Au_LogoutStatistic == 1
//                )
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 77, ItemContent = "馆藏统计", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left8.png" });
//            }
               
//            if (GlobalTracker.User_AuthoritySetting.Au_RoomStruct==1)
//            {
//                 _list.Add( new TreeItemModel() { Level = 2, Id = 78, ItemContent = " 馆藏结构", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "文献库室调配.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_RoomYearStatistic==1)
//            {
//            _list.Add( new TreeItemModel() { Level = 2, Id = 79, ItemContent = " 馆藏年代统计", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "典藏文献剔旧.png" });
//            }

//            //_list.Add( new TreeItemModel(){ Level=2, Id=117,ItemContent=" 馆藏年度变化",ParentId=77,IconPath=GlobalPath.Imgs_Path + "馆藏文献注销.png"});
//            if (GlobalTracker.User_AuthoritySetting.Au_RoomStandardStatistic==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 118, ItemContent = " 馆藏标准对比", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "馆藏文献注销.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_BookInDetails==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 80, ItemContent = " 图书入库明细", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "馆藏文献注销.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_RooListLogin==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 114, ItemContent = " 馆藏总括登记账", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "馆藏文献注销.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_PersonalStatistic==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 115, ItemContent = " 个别登记账", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "馆藏文献注销.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_LogoutStatistic==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 116, ItemContent = " 注销统计账", ParentId = 77, IconPath = GlobalPath.Imgs_Path + "馆藏文献注销.png" });
//            }


//            //// 图书馆网站读者功能
//            //_list.Add( new TreeItemModel(){ Level=1, Id=93,ItemContent="图书馆网站读者功能",ParentId=0,IconPath=GlobalPath.Imgs_Path + "Left11.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=94,ItemContent=" 信息和新闻浏览",ParentId=93,IconPath=GlobalPath.Imgs_Path + "信息与新闻浏览.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=95,ItemContent=" 我的图书馆",ParentId=93,IconPath=GlobalPath.Imgs_Path + "我的图书馆.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=96,ItemContent=" 图书查询",ParentId=93,IconPath=GlobalPath.Imgs_Path + "图书查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=97,ItemContent=" 期刊查询",ParentId=93,IconPath=GlobalPath.Imgs_Path + "期刊查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=98,ItemContent=" 联合查询",ParentId=93,IconPath=GlobalPath.Imgs_Path + "联合查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=99,ItemContent=" 新书查询",ParentId=93,IconPath=GlobalPath.Imgs_Path + "新书查询.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=100,ItemContent=" 读者推荐",ParentId=93,IconPath=GlobalPath.Imgs_Path + "读者推荐.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=101,ItemContent=" 电子资源",ParentId=93,IconPath=GlobalPath.Imgs_Path + "电子资源.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=102,ItemContent=" 图书评论",ParentId=93,IconPath=GlobalPath.Imgs_Path + "图书评论.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=103,ItemContent=" 书刊借阅排行榜",ParentId=93,IconPath=GlobalPath.Imgs_Path + "书刊借阅排行榜.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=104,ItemContent=" 读者自动挂失",ParentId=93,IconPath=GlobalPath.Imgs_Path + "读者自主挂失.png"});
//            //_list.Add( new TreeItemModel(){ Level=2, Id=105,ItemContent=" 读者自动续借",ParentId=93,IconPath=GlobalPath.Imgs_Path + "读者挂失.png"});


//            //系统管理
//            if (GlobalTracker.User_AuthoritySetting.Au_AssistManager == 1|| GlobalTracker.User_AuthoritySetting.Au_HolidayManger == 1|| GlobalTracker.User_AuthoritySetting.Au_UserManager == 1)
//            {
//                _list.Add(new TreeItemModel() { Level = 1, Id = 106, ItemContent = "系统管理", ParentId = 0, IconPath = GlobalPath.Imgs_Path + "Left5.png" });
//            }

              
//            if (GlobalTracker.User_AuthoritySetting.Au_AssistManager==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 107, ItemContent = " 财产管理", ParentId = 106, IconPath = GlobalPath.Imgs_Path + "手机端图书馆功能.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_HolidayManger==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 108, ItemContent = " 学期,假期及节假日管理", ParentId = 106, IconPath = GlobalPath.Imgs_Path + "查询浏览终端.png" });
//            }

//            if (GlobalTracker.User_AuthoritySetting.Au_UserManager==1)
//            {
//                _list.Add(new TreeItemModel() { Level = 2, Id = 109, ItemContent = " 用户管理", ParentId = 106, IconPath = GlobalPath.Imgs_Path + "导入读者.png" });
//            }
                  


//            ///设置样式
//            _SetStyle( _list );

//            return _list;
//        }

//        /// <summary>
//        /// 根据级别设置样式
//        /// </summary>
//        /// <param name="treeItems">节点集合对象</param>
//        private static void _SetStyle(List<TreeItemModel> treeItems)
//        {

//            foreach (var item in treeItems)
//            {
//                if (item.Level==1)
//                {
//                    item.BGcolor = new SolidColorBrush( (Color)ColorConverter.ConvertFromString( "#304a76" ) );
//                    item.BorderThickness = new System.Windows.Thickness( 0 );
//                    item.FontColor = new SolidColorBrush( (Color)ColorConverter.ConvertFromString( "#4ecbc4" ) );
//                    item.FontSize = 16;
//                    item.IconHeight = 25;
//                    item.IconWidth = 25;
//                    item.IconThickness = new Thickness( 0, 4, 15, 4 );
//                }
//                else if(item.Level==2)
//                {
//                    item.BGcolor = new SolidColorBrush( (Color)ColorConverter.ConvertFromString( "#21324f" ) );
//                    item.BorderThickness = new Thickness( 0, 0, 0, 1 );
//                    item.BorderColor= new SolidColorBrush( (Color)ColorConverter.ConvertFromString( "#293b5a" ) );
//                    item.FontColor = new SolidColorBrush( (Color)ColorConverter.ConvertFromString( "#7b96c4" ) );
//                    item.FontSize = 13;
//                    item.IconHeight = 15;
//                    item.IconWidth = 15;
//                    item.IconThickness = new Thickness( 5, 4, 15, 4 );
//                }
//            }

//        }

//        public override List<TreeItemModel> GetTree(int parentId, List<TreeItemModel> nodes)
//        {
//            List<TreeItemModel> _mainNodes = nodes.Where( x => x.ParentId == parentId ).ToList<TreeItemModel>();
//            List<TreeItemModel> _otherNodes = nodes.Where( x => x.ParentId != parentId ).ToList<TreeItemModel>();
//            foreach (TreeItemModel dpt in _mainNodes)
//            {
//                dpt.Nodes = GetTree( dpt.Id, _otherNodes );
//            }
//            return _mainNodes;
//        }
//    }
//}
